package main

import (
	"fmt"
	"strconv"
	"unicode/utf8"
)

const GoUsage = `Go is a tool for managing Go source code
Usage:
	go command [arguments]`

func main() {
	var s string = "\\ooo"
	fmt.Println(GoUsage)
	fmt.Println(s)
	fmt.Println("----------")
	ss := "Hello, 世界"
	fmt.Println(len(ss), utf8.RuneCountInString(ss))
	fmt.Println("----------")
	for i, c := range ss {
		fmt.Printf("%d\t%q\t%d\t\n", i, c, c)
	}
	fmt.Printf("\uFFFD\n")
	fmt.Println("==============")
	rw := "プログラム"
	fmt.Printf("% x\n", rw)
	r := []rune(rw)
	fmt.Printf("%x\n", r)
	fmt.Println("==============")
	fmt.Println(strconv.Itoa(123))
	fmt.Println(fmt.Sprintf("x=%b", 123))
	fmt.Println("==============")
	x, y := 1, 2
	x, y = y, x
	fmt.Println(x, y)
	fmt.Println("-------------")
	const (
		a = 1
		b
		c = 2
		d
	)

	fmt.Println(a, b, c, d) // "1 1 2 2"
}
